PrintCallback

public interface PrintCallback implements BrowserAsyncCallback<P, R>

This callback is invoked when the printing is about to start.

In this callback you can proceed with the printing, cancel it, or display the print preview dialog where you can configure the print settings and print the currently loaded web page. If you choose to proceed with the printing by invoking print, then either PrintHtmlCallback or PrintPdfCallback will be invoked to configure the print settings.

If this callback is invoked when the browser is loading a web page, then the print preview dialog may not be shown, and PrintHtmlCallback or PrintPdfCallback may not be invoked.

By default, the printing is canceled.

You can directly cancel printing by invoking cancel. To print using the print preview dialog, the showPrintPreview method must be invoked.

If the callback throws an exception, the cancel method will be invoked.

Inheritors

Types

Link copied to clipboard
public final class Action extends AsyncCallbackAction<R>
An action providing a response to the PrintCallback.
Link copied to clipboard
public interface Params
The parameters of the PrintCallback.

Functions

Link copied to clipboard
public abstract void on(P params, R tell)
Invoked when the callback needs a response for the given callback parameters.